package com.gqj.meter.domain;

import java.util.Date;

import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModelProperty;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.gqj.common.annotation.Excel;
import com.gqj.common.core.domain.BaseEntity;

/**
 * 告警信息对象 md_warning_info
 *
 * @author lxq
 * @date lxq-02-10
 */
public class MdWarningInfo extends BaseEntity {
    private static final long serialVersionUID = 1L;

    /**
     * 告警标识,告警的记录标识
     */
    @ApiModelProperty("告警标识")
    private Long warningId;

    /**
     * 库房标识
     */
    @ApiModelProperty("库房标识")
    private Long whId;

    /**
     * 管理单位编号
     */
    @ApiModelProperty("管理单位编号")
    private String orgNo;

    /**
     * 告警类型,01:设备告警
     * 02:业务告警
     * 03:温湿度告警
     */
    @ApiModelProperty("告警类型")
    private String warningType;

    /**
     * 告警描述,
     * 告警内容描述如:
     * 0101:柜门损坏
     * 0102:储位损坏
     * 0103:摄像头损坏
     * 0201:单相表库存超期告警
     * 0202:三相表库存超期告警
     * 0203:领出未装超期告警（此时需要把出库任务的工单号插入“告警工单号”字段）
     * 0204:单相表超上限告警
     * 0205:单相表低于下限告警
     * 0206:三相表超上限告警
     * 0207:三相表低于下限告警
     * 0208:低压电流互感器超上限告警
     * 0209:低压电流互感器低于下限告警
     * 0210：采集终端超上限告警
     * 0211：采集终端低于下限告警
     * 0301：温度过高
     * 0302：温度过低
     * 0303：湿度过高
     * 0304：湿度过低
     */
    @ApiModelProperty("告警描述")
    private String warningDescription;

    /**
     * 告警工单号,发生业务告警时关联的业务工单号
     */
    @ApiModelProperty("告警工单号")
    private String warningAppNo;

    /**
     * 告警时间
     */
    @ApiModelProperty("告警时间")
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "告警时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date warningDate;

    public void setWarningId(Long warningId) {
        this.warningId = warningId;
    }

    public Long getWarningId() {
        return warningId;
    }

    public void setWhId(Long whId) {
        this.whId = whId;
    }

    public Long getWhId() {
        return whId;
    }

    public void setOrgNo(String orgNo) {
        this.orgNo = orgNo;
    }

    public String getOrgNo() {
        return orgNo;
    }

    public void setWarningType(String warningType) {
        this.warningType = warningType;
    }

    public String getWarningType() {
        return warningType;
    }

    public void setWarningDescription(String warningDescription) {
        this.warningDescription = warningDescription;
    }

    public String getWarningDescription() {
        return warningDescription;
    }

    public void setWarningAppNo(String warningAppNo) {
        this.warningAppNo = warningAppNo;
    }

    public String getWarningAppNo() {
        return warningAppNo;
    }

    public void setWarningDate(Date warningDate) {
        this.warningDate = warningDate;
    }

    public Date getWarningDate() {
        return warningDate;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE)
                .append("warningId", getWarningId())
                .append("whId", getWhId())
                .append("orgNo", getOrgNo())
                .append("warningType", getWarningType())
                .append("warningDescription", getWarningDescription())
                .append("warningAppNo", getWarningAppNo())
                .append("warningDate", getWarningDate())
                .toString();
    }
}
